package com.neusoft.neuiotms.dcom.model.change;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;

import org.hibernate.validator.constraints.Length;

import com.neusoft.bizcore.web.jpa.model.AbstractAuditModel;
import com.neusoft.bizcore.web.jpa.model.Comment;

import lombok.Getter;
import lombok.Setter;

@Getter
@Setter
@Entity
@Table(name = "neuiot_change_approval")
@org.hibernate.annotations.Table(appliesTo = "neuiot_change_approval", comment = "变更审批表")
public class ChangeApproval extends AbstractAuditModel {

    private static final long serialVersionUID = 1L;

    @Length(max = 255, message = "工作流TaskId不能超过{max}位")
    @Column(length = 255, nullable = true)
    @Comment("varchar(255) NOT NULL COMMENT '工作流TaskId'")
    private String taskId;

    @Length(max = 50, message = "工单号不能超过{max}位")
    @Column(length = 50, nullable = true)
    @Comment("varchar(50) NOT NULL COMMENT '工单号'")
    private String workOrderNum;

    @Column(nullable = false)
    @Comment("varchar(50) NOT NULL COMMENT '意见KEY'")
    private String opinion;

    @Length(max = 255, message = "未通过原因不能超过{max}位")
    @Column(length = 255, nullable = true)
    @Comment("datetime NULL DEFAULT NULL COMMENT '未通过原因'")
    private String reason;

}
